function build_name(firstName:string, ...restOfNames:string[]) {
    return firstName + " " + restOfNames.join(" ")
}

console.log(build_name("zhangsan","lisi","wangwu"));